﻿@model Stardust.Models.ProductoBean

<h2>Registrar Producto</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>


@Html.ValidationSummary(true)
@using (Html.BeginForm("Create", "Producto", FormMethod.Post, new { @class = "form" }))
{
    
    <fieldset>
            <div class="widget">
            <div class="title">
                <h6>Registrar Producto</h6>
            </div>


            <div class="formRow">
                @Html.LabelFor(model => model.nombre)
                <div class = "formRight" >@Html.TextBoxFor(model => model.nombre, new{ placeholder = "Maximo 50 caracteres aqui",maxlength = "50" })
                @Html.ValidationMessageFor(model => model.nombre) @ViewBag.error  </div>

                <div class = "clear" ></div>
            </div>

            <div class="formRow">
                @Html.LabelFor(model => model.descripcion)
                <div class = "formRight" >@Html.TextAreaFor(model => model.descripcion,new { maxlength = "45" })</div>
                 <div class = "clear" ></div>
            </div>
            
           
            </div>
    </fieldset>
            <p></p> <p></p> <p></p>
    <div>
           <input type="submit" value="Crear" class = "redB" />
           @Html.ActionLink("Regresar", "Buscar")
    </div>
}